Convert arbitrary size of byte[] to BigInteger[] and then safely convert back to exactly the same by

Posted by PatlaDJ on Stack Overflow See other posts from Stack Overflow or by PatlaDJ
Published on 2010-03-24T12:15:14Z Indexed on 2010/03/24 12:23 UTC
Read the original article Hit count: 288

Filed under:
|
|
|
|

I believe conversion exactly to BigInteger[] would be optimal in my case. Anyone had done or found this written in Java and willing to share?

So imagine I have arbitrary size byte[] = {0xff,0x3e,0x12,0x45,0x1d,0x11,0x2a,0x80,0x81,0x45,0x1d,0x11,0x2a,0x80,0x81} How do I convert it to array of BigInteger's and then be able to recover it back the original byte array safely?

ty in advance.

© Stack Overflow or respective owner

Related posts about java

Related posts about conversion